#ifndef PAGEFRAME_H
#define PAGEFRAME_H

#include <QtGlobal>
#include <QtPlugin>

#if QT_VERSION >= 0x050000
#include <QtWidgets/QWidget>
#else
#include <QtGui/QWidget>
#endif

class IPageFrame : public QWidget
{
public:
    explicit IPageFrame(QWidget *parent = nullptr)
        : QWidget(parent)
    {
    }

    virtual ~IPageFrame() {}

public:
    virtual void addPage(QWidget* page, const QString& name) = 0;
    virtual void showPage(int index) = 0;
};

QT_BEGIN_NAMESPACE
Q_DECLARE_INTERFACE(IPageFrame,"ipageframe")
QT_END_NAMESPACE

#endif // PAGEFRAME_H
